﻿<%@ Page Title="" Language="C#" MasterPageFile="~/RepairChecker.Master" AutoEventWireup="true" CodeBehind="schedule.aspx.cs" Inherits="RepairChecker.schedule" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <asp:Panel ID="Panel1" runat="server">
        安排主动维护：<br/>
        网点：
        <asp:DropDownList ID="lstDistrict" runat="server" AutoPostBack="True" 
            onselectedindexchanged="lstDistrict_SelectedIndexChanged" Width="80px">
        </asp:DropDownList>
        <asp:DropDownList ID="lstOffice" runat="server" Width="200px">
        </asp:DropDownList>
        <br />
        <asp:Label ID="lblError" runat="server" ForeColor="Red"></asp:Label>
        <br/>
        <asp:Button ID="btnAddMaintaince" runat="server" Text="主动维护" 
            onclick="btnAddMaintaince_Click" />
    </asp:Panel>
    <hr/>
    <asp:ObjectDataSource ID="sourceSchedule" runat="server" 
        SelectMethod="GetJobs" TypeName="RepairChecker.Entity">
        <SelectParameters>
            <asp:Parameter Name="crewId" Type="Int32" DefaultValue="0" />
            <asp:Parameter Name="districtId" Type="Int32" DefaultValue="0" />
            <asp:Parameter DefaultValue="2" Name="showMode" Type="Int32" />
            <asp:Parameter DefaultValue="0" Name="jobTypeId" Type="Int32" />
            <asp:Parameter DefaultValue="" Name="faultIdString" Type="String" />
            <asp:Parameter DefaultValue="0" Name="dateType" Type="Int32" />
            <asp:Parameter DefaultValue="1970-1-1" Name="dateStart" Type="DateTime" />
            <asp:Parameter DefaultValue="1970-1-1" Name="dateEnd" Type="DateTime" />
        </SelectParameters>
    </asp:ObjectDataSource>
    <asp:Button ID="btnReport" runat="server" onclick="btnReport_Click" 
        Text="生成报表" />
    筛选：<asp:DropDownList ID="DropDownList1" runat="server">
    </asp:DropDownList>
    <asp:GridView ID="dataSchedule" runat="server" AutoGenerateColumns="False" 
        BackColor="White" BorderColor="#CCCCCC" BorderStyle="None" BorderWidth="1px" 
        CellPadding="4" DataSourceID="sourceSchedule" ForeColor="Black" 
        GridLines="Horizontal" onrowdatabound="dataSchedule_RowDataBound">
        <Columns>
            <asp:BoundField DataField="DistrictName" HeaderText="区县" 
                SortExpression="DistrictName" />
            <asp:BoundField DataField="OfficeName" HeaderText="网点" 
                SortExpression="OfficeName" />
            <asp:TemplateField HeaderText="股长~">
                <ItemTemplate>
                    <asp:BulletedList ID="lstFaults" runat="server">
                    </asp:BulletedList>
                </ItemTemplate>
            </asp:TemplateField>
            <asp:BoundField DataField="CallInDate" HeaderText="接报时间" 
                SortExpression="CallInDate" />
            <asp:BoundField DataField="NotifyDate" HeaderText="通知时间" 
                SortExpression="NotifyDate" />
            <asp:BoundField DataField="CrewName" HeaderText="维护人猿" 
                SortExpression="CrewName" />
            <asp:BoundField DataField="JobType" HeaderText="报修类型" 
                SortExpression="JobType" />
            <asp:BoundField DataField="Memo" HeaderText="备注" 
                SortExpression="Memo" />
        </Columns>
        <FooterStyle BackColor="#CCCC99" ForeColor="Black" />
        <HeaderStyle BackColor="#333333" Font-Bold="True" ForeColor="White" />
        <PagerStyle BackColor="White" ForeColor="Black" HorizontalAlign="Right" />
        <SelectedRowStyle BackColor="#CC3333" Font-Bold="True" ForeColor="White" />
        <SortedAscendingCellStyle BackColor="#F7F7F7" />
        <SortedAscendingHeaderStyle BackColor="#4B4B4B" />
        <SortedDescendingCellStyle BackColor="#E5E5E5" />
        <SortedDescendingHeaderStyle BackColor="#242121" />
    </asp:GridView>
</asp:Content>
